package com.team1.supervend.domain;

public class PaymentAmount {
	private float amount;

	PaymentAmount( float amount ) {
		this.amount = amount;
	}

	PaymentAmount( ) {
		this.amount = 0.0f;
	}
	
	public float get(){ return amount; }
	public void set( float amount ) { this.amount = amount; }

	public PaymentAmount times( int quantity )
	{ 
		PaymentAmount amountTimesQuantity = new PaymentAmount();
		amountTimesQuantity.set( amount * quantity );
		return amountTimesQuantity; 
	}

	public float add( PaymentAmount increaseAmount )
	{ 
		amount = amount + increaseAmount.get();
		return amount; 
	}

	public float minus( PaymentAmount decreaseAmount )
	{ 
		amount = amount - decreaseAmount.get();
		return amount; 
	}

}
